package ru.urfc.portal.managers;

import java.util.List;

import ru.urfc.portal.dao.filter.Filter;
import ru.urfc.portal.model.AssociationKey;
import ru.urfc.portal.model.AssociationKeyWithEmail;
import ru.urfc.portal.model.Client;
import ru.urfc.portal.model.ClientUpdate;
import ru.urfc.portal.model.accounting.Contragent;
import ru.urfc.portal.model.admins.User;
import ru.urfc.portal.model.admins.UserCreate;
import ru.urfc.portal.model.admins.UserSelfUpdate;
import ru.urfc.portal.model.admins.UserUpdate;

public interface ClientManager {

	List<Client> getClients(Filter branchFilter, Filter spectrFilter);

	Contragent getContragent(Long clientId);

	AssociationKey generateKey(Long clientId);

	Client updateClient(Long clientId, ClientUpdate clientUpdate);

	User getUser(Long clientId, Long userId);

	Client getClient(Long clientId);

	List<User> getUsers(Long clientId);

	User createUser(Long clientId, UserCreate user);

	User updateUser(Long clientId, Long userId, UserUpdate userUpdate);

	User getUserByEmailAndActivate(String email);

	void deleteUser(Long clientId, Long userId);

	User getUserForHimSelf(Long userId);

	User updateUser(Long userId, UserSelfUpdate userSelfUpdate);

	boolean associate(AssociationKeyWithEmail associationKey);

}